home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / macros / lollipop / lollipop.hqx / Lollipop Manual / prelim.tex < prev    next >
Text File  |  1992-11-19  |  13KB  |  318 lines

  1. % Prelim.tex copyright 1992 Victor Eijkhout
  2. %
  3. \Chapter Preliminaries
  4.  
  5. \Section What is Lollipop?
  6.  
  7. Lollipop is `\TeX\ made easy'. Lollipop is a macro package
  8. that functions as a toolbox for writing \TeX\ macros. It was my
  9. intention to make macro writing so easy that implementing a fully new
  10. layout in \TeX\ would become a matter of less than an hour for an
  11. average document, and that it would be a task that could be
  12. accomplished by someone with only a very basic training in \TeX\
  13. programming.
  14.  
  15. Lollipop is an attempt to make structured text formatting available
  16. for environments where previously only wysiwyg packages could be used
  17. because adapting the layout is so much more easy with them than with
  18. traditional \TeX\ macro packages.
  19.  
  20. \Section But is is compatible?
  21.  
  22. Lollipop, like \LaTeX, is not compatible with plain \TeX. I~don't
  23. consider this a real problem. Most plain \TeX\ commands will work in
  24. \Lollipop\ with the exception of anything output routine related.
  25. (See also below.)
  26.  
  27. \Lollipop\ is also not compatible with \LaTeX, although it has a lot
  28. of the same functionality. There are two reasons why \Lollipop\ still
  29. has a reason for existing, even though \LaTeX\ is used pretty much
  30. all over the scientific world.
  31.  
  32. For one, Lollipop is targeted in part
  33. to different users than the typical plain \TeX\ or
  34. \LaTeX\ user. For another, I~have a vain hope that I~can capture some
  35. of the \LaTeX\ market share. Since developing styles in \Lollipop\ is
  36. so much more easier than in \LaTeX, I~may stand a fighting chance.
  37.  
  38. \SubSection \Lollipop\ and plain \TeX
  39.  
  40. Having said the above, I'll conceded that \Lollipop\ is more
  41. compatible with plain \TeX\ than with \LaTeX. You can use quite some
  42. plain \TeX\ commands in \Lollipop. However, stay away from the
  43. following:\Description\item \cs{everypar}
  44. This one is heavily used by \Lollipop. You may use \cs{EveryPar}
  45. instead, which functions pretty much like \cs{everypar}; see
  46. section~\ref[sec:everypar].\item \cs{output}
  47. Page output is done so very differently from plain \TeX\ that all
  48. commands pertaining to page numbers and head/footlines have been
  49. eradicated. (Well, \cs{pageno} still gives the page number.) See
  50. chapter~\ref[chap:output].
  51.  \>
  52.  
  53. The current version of \Lollipop\ is based on the plain \TeX\ file
  54. that comes with \TeX\ version~3.0.
  55.  
  56.  \Section How to Use \Lollipop
  57.  
  58. The following files comprise the Lollipop format:
  59. \Ver>
  60.     fonts.tex       lists.tex
  61.     define.tex      heading.tex     lollipop.tex    text.tex
  62.     document.tex    lolplain.tex    output.tex      tools.tex<Rev
  63. and it is assumed that you have a file called \file{hyphen.tex} with
  64. hyphenation patters for the language you are using.
  65.  
  66. Run \IniTeX\ on \file{lollipop.tex}. On some systems \IniTeX\ is
  67. really called that, on others you may have to type \n{tex/i} or
  68. something like that. With Textures on the Macintosh you typeset using
  69. the `VirTeX' format (you can load \Lollipop\ on top of plain \TeX\
  70. but you then have to ignore the error message about the \cs{patterns}
  71. command).
  72.  
  73.  This gives, depending on your operating system, output that
  74. looks something like this:
  75.  
  76. \Ver>> initex lollipop
  77. This is TeX, C Version 3.0 (INITEX)
  78. (lollipop.tex (lolplain.tex (hyphen.tex)) (tools.tex) (define.tex) (fonts.tex)
  79. (text.tex) (document.tex) (heading.tex) (output.tex) (lists.tex))
  80. Beginning to dump on file lollipop.fmt
  81.  (format=lollipop 92.5.30)
  82. 3102 strings of total length 41719
  83. 27016 memory locations dumped; current usage is 142&26543
  84. 2076 multiletter control sequences
  85. \font\nullfont=nullfont
  86. ...
  87. 2706 words of font info for 12 preloaded fonts
  88. 17 hyphenation exceptions
  89. Hyphenation trie of length 6075 has 181 ops out of 500
  90.   181 for language 0
  91. No pages of output.
  92. Transcript written on lollipop.log.<Rev
  93.  
  94. As a result of this, you get a file \file{lollipop.fmt} that contains
  95. the Lollipop format. This has to be loaded in \TeX\ everytime you want
  96. to format a file. To process a file, say \file{test.tex}, with
  97. Lollipop you then type:
  98. \Ver>
  99. > tex &lollipop test <Rev
  100. or something like that, depending on local conditions (for Unix you
  101. will have to escape the ampersand).
  102.  
  103. \Section Processing a Lollipop file
  104.  
  105. Files that you make to be processed with Lollipop contain of course
  106. the input text, but they also have to contain the design macros that
  107. determine the layout. There are two possibilities for these design
  108. macros:
  109. \Itemize
  110. \item You can simply put them in the same file, either in the
  111. beginning or wherever they are first needed, or
  112. \item You can put the layout definition in a separate file and make a
  113. new format out of that. For instance, if the layout definition of a
  114. book is complicated, processing it each time will be slow, so you
  115. might put it in a file \file{bookstyle.tex}. \IniTeX\ can load this
  116. definition on top of the Lollipop format:
  117. \Ver>
  118. > tex  &lollipopbookstyle
  119. *\dump<Rev
  120. This gives you a format \file{bookstyle.fmt}, which you can use by typing
  121. \Ver>> tex &bookstyle book<Rev
  122. \>
  123.  
  124. Also in the case where the style designer and the style user are on
  125. different levels of \TeX pertise it may be wise to hide the style
  126. definition from the user by making only a format available.
  127.  
  128. \ImpNote
  129. The file \file{lollipop.tex} contains a \cs{dump} command. This is
  130. not the way plain \TeX\ and \LaTeX\ operate, but I~like this better.
  131. \ImpNoteStop
  132.  
  133. \Section The errors of \Lollipop / known bugs
  134.  
  135. Since \Lollipop\ is an order of magnitude more powerful
  136. (and hence complicated) than formats such as \LaTeX, its error
  137. messages can also be an order of magnitude more cryptic. Fortunately,
  138. \Lollipop\ is also quite a bit better than existing formats at
  139. catching potential errors. Typos in a style definition will usually
  140. lead to warning messages, and also during run time \Lollipop\ is able
  141. to track down ommisions.
  142.  
  143. In addition, you can switch on various trace modes to get more
  144. detailed information about \Lollipop's thought processes. See
  145. chapter~\ref[chap:tracing].
  146.  
  147. These are the known bugs in \Lollipop\ at the moment.
  148.  
  149. \Enumerate\item Local references have been insufficiently tested,
  150. and the code definitely is buggy.
  151. \item The `firstpage' test in the page grids does not work.
  152. \item Titles get written to the aux file with double spaces.
  153. This shouldn't cause any problem, but it has to be fixed.
  154. \item Rules in page grids get white space around them.
  155. \item External items shouldn't declare \cs{FooTitle} or 
  156. \cs{FooCounter}.
  157.  \>
  158.  
  159. \Section About this manual
  160.  
  161. This manual is an unashamed hodge-podge. Apart from the regular
  162. sections (the ones you are supposed to read) there are implementor's
  163. sections, which you read only at your peril. They document the
  164. internals of \Lollipop\ in all their unscrutability.
  165.  
  166. This manual consists of a main file \file{manual.tex}, and the
  167. following input files:
  168. \Ver>
  169. titlepag.tex prelim.tex struct.tex head.tex list.tex
  170. out.tex extern.tex opt.tex comm.tex trace.tex appendix.tex<Rev
  171. and the style definition file \file{mandefs.tex}.
  172.  
  173. In addition, you need \file{comment.tex} which is used to format this
  174. manual, but it is not really a part of \Lollipop.
  175.  
  176. If you format this manual (which you'll have to do three times
  177. to get the page numbering and the table of contents straight) you'll
  178. notice something strange. The file \file{example.tex} is read in
  179. many, many times. This is because this manual formats its examples
  180. along the way, first writing them out, and then reading them in to
  181. show both their code and their output. This way it is guaranteed that
  182. the examples in the manual will always work.
  183.  
  184. As a result of formatting this manual you will wind up with, apart
  185. from the usual \file{dvi} file, with \file{manual} files
  186. with extensions \file{aux}, \file{toc}, and \file{imp}; 
  187. \file{oix} and \file{cix} for indexes of options and commands,
  188. and
  189. \file{tct}, file{tix} which are for the examples.
  190.  
  191. This manual needs quite some resources: here's what \TeX\ told me
  192. it needed.
  193. \Ver>Here is how much of TeX's memory you used:
  194.  1259 strings out of 4808
  195.  14894 string characters out of 21967
  196.  62606 words of memory out of 65536
  197.  3042 multiletter control sequences out of 10000
  198.  19 hyphenation exceptions out of 307
  199.  22i,4n,24p,225b,502s stack positions out of 
  200.  200i,60n,60p,5000b,2000s<Rev
  201. This should not need a `Big \TeX', but it comes close.
  202.  
  203. \Section The most boring section in this manual
  204.  
  205. There are a few things about \Lollipop\ that I~want to be clear about.
  206.  
  207. \SubSection I am going to hurt you and I am not sorry
  208.  
  209. In the secret handbook for the software industry it says that the
  210. final test phase of a product consists of putting it in stores and
  211. having innocent suckers pay good money for it. (You guessed it, this
  212. is the disclaimer section.) So let me just say that 
  213. \Lollipop\ is probably good for nothing, at least, I~don't claim it
  214. is. And if you hurt yourself by using it, don't blame me. I~warned
  215. you.
  216.  
  217. \SubSection Get a \Lollipop, give one away
  218.  
  219. \Lollipop\ is free software. You may copy it
  220. for your own purposes, or give away copies. However, you may not ask
  221. money for it, other than reasonable expenses such as for copying discs
  222. or manuals. If you make changes to \Lollipop\ these should be clearly
  223. indicated as such if you give away copies.
  224.  
  225. The easiest way to get the current copy of \Lollipop\ is to ftp it
  226. from \n{cs.utk.edu} from the directory \n{/pub/eijkhout/tex} where it
  227. is stored as \n{lollipop.tar.Z}. Starting with version 0.93 there
  228. is also a self-extracting Macintosh archive.
  229.  
  230. \SubSection The status of \Lollipop
  231.  
  232. \Lollipop\ is still under development. Although I~will try not to
  233. make any drastic changes in the user interface (this says nothing
  234. about the internals!) I~really cannot guarantee anything.
  235. However, I~do listen to complaints and suggestions. 
  236.  
  237. If you have suggestions or complaints about the
  238. useability of \Lollipop\ or the implementation, feel free to contact
  239. me at \cs{eijkhout@cs.utk.edu} on the Internet. Or send snail mail
  240. to:
  241. \Ver>    Victor Eijkhout
  242.     Department of Computer Science
  243.     University of Tennessee
  244.     107 Ayres Hall
  245.     Knoxville TN 37996
  246.     USA<Rev
  247.  
  248. \SubSection[sec:wish:list] The wish list
  249.  
  250. \Lollipop\ is not quite perfect. Here's a list of things that I~am
  251. going to be adding in the near future. If you want to add items to
  252. this list, just mail me.
  253.  
  254. \Enumerate\item Raggedbottom should really, really be added. Soon!
  255.  
  256. \item Capitalization and initial capping of titles. If a
  257. title appears in mixed case, it should be possible to have it in all
  258. uppercase in running heads.
  259.  
  260. \item A better multi-column mode.
  261.  
  262. \item Interface to Bib\TeX.
  263.  
  264. \item Inserts, in particular footnotes. At the moment floating
  265. figures are entirely lacking. (As a matter of fact, the plain \TeX\
  266. macros are availble, but I'm not telling that.)
  267.  
  268. \item Adaptive list indents. Calculate the maximum needed
  269. indentation, write that to the \file{.aux} file, and read it in next
  270. time. Also do this globally, and have the possibility to have this
  271. spill over into the \cs{parindent} and such.
  272.  
  273. \item A `nomarks' option to prevent wasting two token lists.
  274. Maybe other recourse saving optio for the expert designer?
  275.  
  276. \item More sophisticated white space right before and after
  277. page breaks. (Use at least so and so much.)
  278.  
  279. \item Dynamic topskip.
  280.  
  281. {\PopIndentLevel\Indent:no The following points are debatable:
  282. maybe I~should just steal a few components from \LaTeX. Maybe this
  283. sort of stuff does not belong in \Lollipop.\par}
  284.  
  285. \item A tabular mode. Personally I~always felt \cs{halign} to be more
  286. than sufficient, but some people seem to think otherwise.
  287.  
  288. \item Maths constructs. Some things in the \cs{eqalign} vein would be
  289. nice.
  290.  
  291. \>
  292.  
  293. \SubSection A bit of history
  294.  
  295. The \Lollipop\ format was begun in late 1989 to typeset my Ph.D.
  296. thesis, `{\Style:italic Vectorizable and Parallelizable
  297. Preconditioners for the Conjugate Gradient Method}'. At that time 
  298. I~was using \TeX\ on an Atari 1040ST.
  299. Loading the style definition for the thesis took about two minutes.
  300. \Lollipop\ was heavily augmented in late 1991 to typeset my book
  301. `{\Style:italic \TeX\ by Topic}', for which I~used Sun~3 and Sun~4
  302. computers. Writing this manual brought \Lollipop\ to its present
  303. state; the first public release (version~0.9) was announced on the
  304. internet in October 1992. At present I~am using Lightning Textures on a
  305. Macintosh Powerbook~145.
  306.  
  307. The name `\cs{Lollipop}' refers to a quote by Alan Perlis on page 365
  308. of the \TeX book. In a way it's rather pretentious. The philosophy of
  309. the \cs{Lollipop} format is described in a paper that I~wrote with
  310. Andries Lenstra (Tugboat volume~12 nr~1). A~further peek at
  311. \Lollipop\ was given to the participants of the Portland TUG meeting;
  312. a~paper based on this talk can be found in Tugboat volume~13 nr~3.
  313.  
  314. \endinput
  315.  
  316. 92/10/22 historical remark about name added
  317. 92/11/03 section 'Lollipop and plain TeX' added;
  318.          remarks about IniTeX in Textures